<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML Basic 1.0//EN"    "http://www.w3.org/TR/xhtml-basic/xhtml-basic10.dtd">
<%@ page language="java" contentType="application/xhtml+xml; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@page import="org.j4me.deviceinfo.data.*"%>
<%@page import="java.util.*"%>
<%@page import="java.net.URLEncoder"%>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="application/xhtml+xml;; charset=UTF-8" />
<title>J4ME - Devices database - Home</title>
</head>
<body>

<%
DeviceDb db = DeviceDb.getInstance();
%>


<h2>J4ME - Devices Database </h2>


<p>Developper, this site is for you !<br/>It shows a collection of device where J4ME is known to run.</p>
<p>For each device, you will find information on supported JSRs , media encoding, ...</p>
<p>If your device is not present in this database, then feel free to run the <a href="m/j4info.jad">J4INFO midlet</a>  on your device, then press the Publish key to share this knowledge with other developpers : this will add your result to the device database. The midlet is locate on <a href="m">http://j4me.crickee.net/m</a></p>

<p>Additionally, you may be interested to get the database for your own. For example, It will be useful for building an Over-The-Air site using the "User-Agent" field.  <a href="database.jsp">Download the xml file</a></p>   
 
<p>This site and its associated midlet are in alpha releases, and we get a very few devices. So, you're help is needed to get more and more information in this database. To do so : please download the midlet and publish its result !.</p>

<p>The source code of this project is not yet available, but I will be in a few weeks</p>

<p>Jean-Marie Hermelin<br/> 11 February 2008<br/>manitoba (at)  free (dot) fr </p>  


<h2>Database </h2>

<table>
<tr><td>Last Update</td><td><%=db.getLastModified().toLocaleString() %></td></tr>
<tr><td>Brand count</td><td><%=db.getBrandCount() %></td></tr>
<tr><td>Model count</td><td><%=db.getModelCount() %></td></tr>
<tr><td>Device count</td><td><%=db.getDeviceCount() %></td></tr>
<tr><td>Hit count</td><td><%=db.getHitCount() %></td></tr>
</table>

<p/>

<table >
<tr><td>Brand</td><td>Device Model</td></tr>

<%
Enumeration<Brand> brands = db.getBrands();
while(brands.hasMoreElements())
{
	Brand b = brands.nextElement();
	%>
    <tr><td align="vtop"><%=b.getName() %></td><td>
	<ul>
	<%
	Enumeration<Model> models = b.getModels();
	while(models.hasMoreElements())
	{
		Model m = models.nextElement();
		%>
		<li><a href="model.jsp?b=<%=URLEncoder.encode(b.getName())%>&amp;m=<%=URLEncoder.encode(m.getName())%>" ><%=m.getName() %></a></li>
	<% 
	}
	
	%>
	</ul>	
	
	</td>
	</tr>
<% 
}

%>
</table>
<p/>
<address>user-agent [<%=request.getHeader("User-agent") %>]</address>
</body>
</html>

